import service from '@/utils/request'

// 藏品列表
export const collectionList = (params) => {
  return service({
    url: '/collection/collection/list',
    method: 'get',
    params
  })
}

// 创建藏品
export const createCollection = (data) => {
  return service({
    url: '/collection/collection/create',
    method: 'post',
    data
  })
}

// 更新藏品
export const updateCollection = (data) => {
  return service({
    url: '/collection/collection/update',
    method: 'post',
    data
  })
}

// 删除藏品
export const deleteCollection = (data) => {
  return service({
    url: '/collection/collection/delete',
    method: 'post',
    data
  })
}

// 批量删除藏品
export const deleteCollectionByIds = (data) => {
  return service({
    url: '/collection/collection/deleteByIds',
    method: 'post',
    data
  })
}

// 更新状态
export const changeStatus = (data) => {
  return service({
    url: '/collection/collection/changeStatus',
    method: 'post',
    data
  })
}

// 藏品详情
export const collectionDetail = (params) => {
  return service({
    url: '/collection/collection/detail',
    method: 'get',
    params
  })
}

// 藏品文件列表
export const collectionFileList = (params) => {
  return service({
    url: '/collection/collectionFile/list',
    method: 'get',
    params
  })
}

// 藏品文件详情
export const collectionFileDetail = (params) => {
  return service({
    url: '/collection/collectionFile/detail',
    method: 'get',
    params
  })
}

// 添加藏品文件
export const addCollectionFile = (data) => {
  return service({
    url: '/collection/collectionFile/create',
    method: 'post',
    data
  })
}

// 编辑藏品文件
export const updateCollectionFile = (data) => {
  return service({
    url: '/collection/collectionFile/update',
    method: 'post',
    data
  })
}

// 删除藏品文件
export const deleteCollectionFile = (data) => {
  return service({
    url: '/collection/collectionFile/delete',
    method: 'post',
    data
  })
}

// 批量删除藏品文件
export const deleteCollectionFileByIds = (data) => {
  return service({
    url: '/collection/collectionFile/deleteByIds',
    method: 'post',
    data
  })
}

// 全部品牌列表
export const brandListAll = (params) => {
  return service({
    url: '/collection/brand/listAll',
    method: 'get',
    params
  })
}
